<!DOCTYPE html>
<html lang="en">

<head>
    <meta charset="UTF-8">
    <meta http-equiv="X-UA-Compatible" content="IE=edge">
    <meta name="viewport" content="width=device-width, initial-scale=1.0">
    <title>Animation CSS</title>
    <style>
        @keyframes change-color {
            0% {
                background-color: red;
                color: white;
            }

            30% {
                background-color: green;
                color: white;
            }

            60% {
                background-color: blue;
                color: white;
            }

            100% {
                background-color: yellowgreen;
            }
        }

        div:hover {
            animation: change-color 5s linear;
        }

        div {
            width: 200px;
            height: 50px;
            margin: 100px auto;
            border: 1px solid black;
        }
    </style>
</head>

<body>
    <div>Web前端开发</div>
</body>

</html>